Benjamin Otte [Thu, 1 Nov 2012 23:06:02 +0000 (00:06 +0100)]
sizegroup: Use for loops
For loops to loop over lists look nicer and actually do the right thing
with "break" and "continue" statements. So they are vastly preferred to
while loops.
Benjamin Otte [Thu, 1 Nov 2012 22:58:23 +0000 (23:58 +0100)]
sizegroups: Restructure code
This way, we do the checks at the start of the effected function, not
before calling it.
Benjamin Otte [Thu, 1 Nov 2012 22:41:38 +0000 (23:41 +0100)]
sizegroup: Don't cache the sizes anymore
This simplifies code and because sizes are cached by the widgets
themselves, it's not a large performance problem (unless people use huge
amounts of widgets in a single size group, but who does that?
Federico Mena Quintero [Fri, 2 Nov 2012 20:13:02 +0000 (14:13 -0600)]
Merge branch 'bgo687196-filesystemmodel-crash'
Federico Mena Quintero [Thu, 1 Nov 2012 23:48:23 +0000 (17:48 -0600)]
bgo#687196 - Fix model corruption during file removal
The main problem is that we were emitting the row-deleted signal for the model in the middle
of the process that actually deletes the row from the model (remove the row from the array,
update the model->file_lookup hash table, etc.). In the model's caller, one of the row-deleted
callbacks was requesting an iter, which caused the model to revalidate itself - but it did
this while it was in an inconsistent state. This led to an assertion failure later when the
model resorted itself.
The fix in remove_file() is like this:
* The filteredness/visibility of the deleted node is not updated. The
node will simply be gone; we don't need to update those values at
all.
* We invalidate just the node that is being deleted.
* The model->file_lookup hash table is not completely nuked; instead,
we carefully adjust its indices.
* The row-deleted signal is only emitted at the very end, when
deletion is complete and the model is consistent.
Many thanks to William Hua for doing the detective work on this bug!
Signed-off-by: Federico Mena Quintero <federico@gnome.org>
Federico Mena Quintero [Thu, 1 Nov 2012 23:21:47 +0000 (17:21 -0600)]
Make freeze_updates() and thaw_updates() static functions
They were in the semi-public API of GtkFileSystemModel, but never actually used outside of it.
Signed-off-by: Federico Mena Quintero <federico@gnome.org>
Federico Mena Quintero [Thu, 1 Nov 2012 23:19:10 +0000 (17:19 -0600)]
Comments on how the filtering and sorting processes work
Signed-off-by: Federico Mena Quintero <federico@gnome.org>
Benjamin Otte [Thu, 1 Nov 2012 19:22:35 +0000 (20:22 +0100)]
sizegroup: Always at least use widget's size
When widgets were hidden, they were otherwise assigned a 0 size.
Benjamin Otte [Thu, 1 Nov 2012 11:23:42 +0000 (12:23 +0100)]
settings: Reset all styles when the enable-animations settings changes
https://bugzilla.gnome.org/show_bug.cgi?id=686021
Benjamin Otte [Thu, 1 Nov 2012 11:16:06 +0000 (12:16 +0100)]
Raleigh: Fix spinners with disabled animations
When animations are disabled, active and inactive spinners should look
different.
https://bugzilla.gnome.org/show_bug.cgi?id=686021
Benjamin Otte [Wed, 31 Oct 2012 23:22:39 +0000 (00:22 +0100)]
cssimage: Implement some equal functions
Federico Mena Quintero [Thu, 1 Nov 2012 02:54:02 +0000 (20:54 -0600)]
Remove argument to _gtk_file_system_model_update_file() that should not be part of the internal API
Signed-off-by: Federico Mena Quintero <federico@gnome.org>
Federico Mena Quintero [Thu, 1 Nov 2012 02:21:47 +0000 (20:21 -0600)]
Rename gtk_tree_path_new_from_node() to tree_path_new_from_node()
This is a function internal to the file system model; let's not pollute the gtk_tree_path namespace.
Also, make the 'i' variable into 'r' as it refers to a row index, not a file-array index (for
consistency with the docs and the rest of the code).
Signed-off-by: Federico Mena Quintero <federico@gnome.org>
Cosimo Cecchi [Sun, 28 Oct 2012 19:01:30 +0000 (15:01 -0400)]
icon-theme: support loading symbolic GFileIcons from generic URIs
Right now we support loading and recoloring symbolic GFileIcons, but
only if the underlying GFile has a local path. This breaks when the
GFileIcon is loaded from a GResource, which is a reasonable option for an
application that wants to ship a custom symbolic icon.
This patch changes GtkIconInfo to store a GFile together with the file
path, and changes the symbolic icon lookup code to use the GFile URI,
which transparently makes the code work also for GResources.
https://bugzilla.gnome.org/show_bug.cgi?id=687059
Benjamin Otte [Sat, 27 Oct 2012 01:22:03 +0000 (03:22 +0200)]
themingbackground: Remove struct members
... and put them in the only function they are used in.
Benjamin Otte [Sat, 27 Oct 2012 01:17:43 +0000 (03:17 +0200)]
reftests: Add reftest for fractional border sizes
Benjamin Otte [Sat, 27 Oct 2012 01:16:35 +0000 (03:16 +0200)]
themingengine: Draw fradctional border sizes
Benjamin Otte [Sat, 27 Oct 2012 00:40:14 +0000 (02:40 +0200)]
reftests: Fix linear-gradient reftest
... and add it to the Makefile
Benjamin Otte [Sat, 27 Oct 2012 00:25:36 +0000 (02:25 +0200)]
themingbackground: Remove GtkThemingBackgroundLayer
The struct was just the index. So just pass the index around instead of
a full struct.
Benjamin Otte [Sat, 27 Oct 2012 00:23:23 +0000 (02:23 +0200)]
themingbackground: Use get_box() for background image size
Benjamin Otte [Sat, 27 Oct 2012 00:16:42 +0000 (02:16 +0200)]
themingbackground: Introduce gtk_theming_background_get_box()
to query the different clip boxes used by the background drawing code.
Use this function to query these boxes when clipping.
Benjamin Otte [Sat, 27 Oct 2012 00:07:43 +0000 (02:07 +0200)]
themingbackground: Add content_box variable
... to go with border_box and padding_box.
Benjamin Otte [Fri, 26 Oct 2012 23:55:41 +0000 (01:55 +0200)]
themingbackground: Get rid of flags variable
Benjamin Otte [Fri, 26 Oct 2012 23:52:08 +0000 (01:52 +0200)]
themingbackground: Move image variable
... from the Layer struct onto the stack of the only function using it.
Benjamin Otte [Fri, 26 Oct 2012 23:39:30 +0000 (01:39 +0200)]
themingbackground: Restructure code some more
Move variable initialization outside the first code with side effects.
This allows adding some more early returns, including one for code that
used to trigger g_return_if_fail() in certain corner cases.
Benjamin Otte [Fri, 26 Oct 2012 23:35:00 +0000 (01:35 +0200)]
themingbackground: Restructure code
Make if statements encompassing the whole function into early returns.
The rest of the diff is reindenting.
Benjamin Otte [Fri, 26 Oct 2012 23:31:59 +0000 (01:31 +0200)]
cssimage: Add a warning for drawing empty images
width and height of an image must be > 0 for the image to get drawn.
It's up to the code further up to ensure that this is not happening.
Benjamin Otte [Fri, 26 Oct 2012 21:38:19 +0000 (23:38 +0200)]
reftests: Add a reftest for recent commit
Check that a computed background-size of 0 is treated as 0.
Benjamin Otte [Fri, 26 Oct 2012 21:36:39 +0000 (23:36 +0200)]
cssvalue: Compute "background-size: 0 0" properly
Previously a computed value of 0 was treated as "auto", which is wrong.
Benjamin Otte [Fri, 26 Oct 2012 21:33:40 +0000 (23:33 +0200)]
stylecontext: Don't use bg image in gtk_style_context_set_background()
Old code tried to use the "background-image" proeprty for setting the
default image background. While this used to work in the early days of
GTK3, today it is grossly misleading as the backgronud image may be
resized, repositioned and semi-translucent which causes very weird
artifacts when rendering.
So we use the background-color only instead.
Benjamin Otte [Thu, 11 Oct 2012 10:10:20 +0000 (12:10 +0200)]
cssimage: Add an equal vfunc
No implementations for it exist yet.
Benjamin Otte [Thu, 11 Oct 2012 09:48:32 +0000 (11:48 +0200)]
menuitem: Draw background unconditionally
Benjamin Otte [Wed, 19 Sep 2012 14:41:19 +0000 (16:41 +0200)]
settings: Use _gtk_css_provider_load_named()
This way we create one provider per settings object instead of stuffing
it into a global unchanging never-deleting hash table.
Also, we now reload the theme when instructed instead of keeping the old
loaded (and possibly stale) data forever.
https://bugzilla.gnome.org/show_bug.cgi?id=683896
Benjamin Otte [Wed, 19 Sep 2012 14:30:27 +0000 (16:30 +0200)]
cssprovider: Move fallback code into _gtk_css_provider_load_named()
This makes sure the full theme loading logic resides in one function and
isn't scattered around.
As a side-effect, the hash table kept by gtk_css_provider_get_named()
will now be populated with fallback themes. This will not be a problem
after the next commit though.
Benjamin Otte [Wed, 19 Sep 2012 14:15:05 +0000 (16:15 +0200)]
cssprovider: Export gtk_css_provider_load_named) function
... and document it.
For now, the function is only exported internally.
Benjamin Otte [Wed, 19 Sep 2012 14:07:39 +0000 (16:07 +0200)]
cssprovider: Split out theme loading function
Split maintaining the global themes hash table and the theme loading
code into two functions.
This also fixes leaking the provider when loading a theme from a builtin
resource.
Fran Diéguez [Wed, 31 Oct 2012 09:52:47 +0000 (10:52 +0100)]
Updated Galician translations
Sandeep Sheshrao Shedmake [Wed, 31 Oct 2012 05:09:01 +0000 (10:39 +0530)]
Updated Marathi Translations
Wolfgang Stoeggl [Tue, 30 Oct 2012 18:45:59 +0000 (19:45 +0100)]
Updated German translation
Mattias Põldaru [Tue, 30 Oct 2012 13:38:09 +0000 (15:38 +0200)]
[l10n] Updated Estonian translation
Matej Urbančič [Mon, 29 Oct 2012 21:33:43 +0000 (22:33 +0100)]
Updated Slovenian translation
Aurimas Černius [Mon, 29 Oct 2012 20:07:22 +0000 (22:07 +0200)]
Updated Lithuanian translation
Ran Benita [Fri, 26 Oct 2012 00:52:30 +0000 (02:52 +0200)]
wayland: update to work with stable libxkbcommon
libxkbcommon has had some changes to its API. However, it now has a
stable release (0.2.0), so this makes the necessary changes, and
replaces all uses of the deprecated API.
Signed-off-by: Ran Benita <ran234@gmail.com>
Daniel Mustieles [Mon, 29 Oct 2012 12:07:29 +0000 (13:07 +0100)]
Updated Spanish translation
Andika Triwidada [Mon, 29 Oct 2012 11:45:22 +0000 (18:45 +0700)]
Updated Indonesian translation
Sweta Kothari [Mon, 29 Oct 2012 10:58:12 +0000 (16:28 +0530)]
Updated gujarati file
Мирослав Николић [Mon, 29 Oct 2012 10:48:33 +0000 (11:48 +0100)]
Updated Serbian translation
Hib Eris [Sun, 28 Oct 2012 19:05:23 +0000 (20:05 +0100)]
Fix compiling for win32
https://bugzilla.gnome.org/show_bug.cgi?id=687066
Carlos Garnacho [Fri, 26 Oct 2012 15:57:03 +0000 (17:57 +0200)]
texthandles: Add an extra style class to the cursor-mode handle
Themes may want to render handles differently depending on whether
the widget is in selection mode (2 handles enclosing a selection) or
cursor mode (one handle pointing out the insertion cursor).
Carlos Garnacho [Fri, 26 Oct 2012 15:48:26 +0000 (17:48 +0200)]
texthandles: set input shape on handles' window
This improves both interaction and theming, as it allows
arbitrary handle shapes while just being draggable from
the visible areas.
This way themes can set up handles with the hotspot visually
displaced from the horizontal center, as long as the hotspot
lies centered in the image/svg asset.
Carlos Garnacho [Fri, 26 Oct 2012 15:46:40 +0000 (17:46 +0200)]
texthandle: Fix shape setup on non-composited environments
The check on the handle to be drawn on the mask was based on the yet to
be set priv->windows pointers, pass explicitly the handle position to
have the shape correctly initialized on non-composited environments
Nilamdyuti Goswami [Fri, 26 Oct 2012 08:53:33 +0000 (14:23 +0530)]
Assamese translation updatedas.po
John Ralls [Thu, 25 Oct 2012 17:58:47 +0000 (10:58 -0700)]
Rūdolfs Mazurs [Wed, 24 Oct 2012 12:14:37 +0000 (15:14 +0300)]
Updated Latvian translation
Kristian Høgsberg [Wed, 24 Oct 2012 02:37:02 +0000 (22:37 -0400)]
configure.ac: Look for wayland-client 1.0.0
Matthias Clasen [Tue, 23 Oct 2012 21:36:17 +0000 (17:36 -0400)]
Add GDK_VERSION_3_8
This macro is needed for the new AVAILABLE_IN and DEPRECATED_IN
macros.
Tom Tryfonidis [Tue, 23 Oct 2012 16:54:51 +0000 (19:54 +0300)]
Updated Greek translation
Matthias Clasen [Tue, 23 Oct 2012 00:45:02 +0000 (20:45 -0400)]
Bump version
Matthias Clasen [Tue, 23 Oct 2012 00:44:24 +0000 (20:44 -0400)]
3.7.0
Matthias Clasen [Mon, 22 Oct 2012 23:42:41 +0000 (19:42 -0400)]
Be robust against unrealized windows in GtkWindowAccessible
Based on a patch by Albert Astals Cid,
https://bugzilla.gnome.org/show_bug.cgi?id=686152
Matthias Clasen [Mon, 22 Oct 2012 23:41:14 +0000 (19:41 -0400)]
Forgotten fixup
This was meant to be included in the previous commit :-(
Stefano Facchini [Thu, 27 Sep 2012 17:07:42 +0000 (19:07 +0200)]
treeview: Add support for styling the dragged header
https://bugzilla.gnome.org/show_bug.cgi?id=684980
Stefano Facchini [Thu, 27 Sep 2012 16:08:44 +0000 (18:08 +0200)]
treeview: Move the dragged header in the headers window
https://bugzilla.gnome.org/show_bug.cgi?id=684980
Matthias Clasen [Mon, 22 Oct 2012 22:58:32 +0000 (18:58 -0400)]
Use named union for _GtkSymbolicColor in gtk/gtksymboliccolor.c
Patch by Richard Lloyd,
https://bugzilla.gnome.org/show_bug.cgi?id=686366
Cosimo Cecchi [Mon, 22 Oct 2012 22:39:42 +0000 (18:39 -0400)]
scrollbar: remove unused variable
My bad.
Cosimo Cecchi [Thu, 20 Sep 2012 00:56:26 +0000 (20:56 -0400)]
notebook: return TRUE for drag-motion event when over tabs
The GtkNotebook drag-motion event handler may install a timeout when
hovering over a tab, in order to switch to it.
On the other hand it's desirable for applications to use the empty tab
area as a drop target, so the drag-motion handler returns FALSE
(also in case it installs the switch tab timeout), as explained in
https://bugzilla.gnome.org/show_bug.cgi?id=350665.
Unfortunately, applications can use the tab label widget (or a child
of it) as a different drop target area, and install their own
drag-motion handler there.
In this scenario, the timeout will still be installed by GtkNotebook's
handler, but since it returns FALSE, it will never get the matching
drag-leave event, causing it to trigger also when the mouse pointer
moved elsewhere before it expired.
Fix this by returning TRUE from drag-motion when the event is over a
tab. Note that this makes automatic tab switching not work anymore when
drag and drop is handled in the tab label widget; applications are
expected to also handle tab switching if desired in such a case.
https://bugzilla.gnome.org/show_bug.cgi?id=684415
Cosimo Cecchi [Wed, 19 Sep 2012 21:01:00 +0000 (17:01 -0400)]
notebook: consolidate code to remove the switch tab timer
https://bugzilla.gnome.org/show_bug.cgi?id=684415
Mattias Põldaru [Mon, 22 Oct 2012 19:01:01 +0000 (22:01 +0300)]
[l10n] Updated Estonian translation
Cosimo Cecchi [Mon, 22 Oct 2012 17:13:11 +0000 (13:13 -0400)]
scale: update style properties on GtkRange at init
Same fix as in
ef027c93d49e2e31ccb8c181d0096c705c141906, but for
the GtkScale subclass of GtkRange.
https://bugzilla.gnome.org/show_bug.cgi?id=686280
Cosimo Cecchi [Mon, 22 Oct 2012 15:42:55 +0000 (11:42 -0400)]
scrollbar: update style properties on GtkRange at init
GtkScrollbar used to rely on style-updated being emitted every time
after the widget was created in order to set the right values from its
style properties on GtkRange.
Nowadays we try to be smarter and avoid emitting style-updated at
creation time, so we need to manually initialize the GtkRange values.
This fixes a regression from
35e36b9fe506143f722a00f26a86143f9c95b740.
https://bugzilla.gnome.org/show_bug.cgi?id=686280
Jean Parpaillon [Mon, 15 Oct 2012 14:16:51 +0000 (14:16 +0000)]
Fix out of source tree building for gdk/broadway
This patch fix compilation when building out of source tree (gdk/broadway dir).
Signed-off-by: Colin Walters <walters@verbum.org>
Pavol Šimo [Sat, 20 Oct 2012 18:46:03 +0000 (19:46 +0100)]
Updated Slovak translation
Fran Diéguez [Sat, 20 Oct 2012 11:09:24 +0000 (13:09 +0200)]
Updated Galician translations
Tim-Philipp Müller [Sat, 20 Oct 2012 10:25:02 +0000 (11:25 +0100)]
docs: fix typo on 'Getting Started with Gtk+' page
Aurimas Černius [Fri, 19 Oct 2012 17:45:59 +0000 (20:45 +0300)]
Updated Lithuanian translation
Petr Kovar [Fri, 19 Oct 2012 11:25:50 +0000 (13:25 +0200)]
Update Czech translation
Scott Moreau [Wed, 17 Oct 2012 02:38:41 +0000 (20:38 -0600)]
wayland: Update to reflect protocol changes
Fran Diéguez [Thu, 18 Oct 2012 08:53:55 +0000 (10:53 +0200)]
Update Galician translations
Matej Urbančič [Thu, 18 Oct 2012 06:16:39 +0000 (08:16 +0200)]
Updated Slovenian translation
Matthias Clasen [Thu, 18 Oct 2012 01:21:09 +0000 (21:21 -0400)]
Fix duplicate columns in filechooser entry completion
This partically reverts commit
331bba1ad6c5d9535fc5a827b91019f5824e25a7, which broke documented
behaviour.
Cosimo Cecchi [Wed, 17 Oct 2012 21:02:53 +0000 (17:02 -0400)]
menubutton: don't refer to the non-existant menu property
7c6454246e7fa181d9e16f3520bc6d3765168f40 removed the property, but
forgot to change the name in a g_object_notify().
Мирослав Николић [Wed, 17 Oct 2012 20:24:36 +0000 (22:24 +0200)]
Updated Serbian translation
Andika Triwidada [Wed, 17 Oct 2012 16:53:04 +0000 (23:53 +0700)]
Updated Indonesian translation
Daniel Mustieles [Wed, 17 Oct 2012 16:05:57 +0000 (18:05 +0200)]
Updated Spanish translation
Stefano Facchini [Wed, 17 Oct 2012 14:09:08 +0000 (16:09 +0200)]
level-bar: Fix typo
Cosimo Cecchi [Wed, 17 Oct 2012 04:59:59 +0000 (00:59 -0400)]
scrolledwindow: set GDK_EXPOSURE_MASK on the overshoot window
Currently we use gtk_style_context_set_background() when the state flags
change in order to propagate the background color to the overshoot
window, but this is actually only needed because the window doesn't get
expose events, since we always draw a full background in draw().
This also fixes some problems when the GdkWindow of the scrolled
window's child is composited, as seen in oxygen-gtk3.
https://bugzilla.gnome.org/show_bug.cgi?id=686265
Stefano Facchini [Tue, 18 Sep 2012 12:19:01 +0000 (14:19 +0200)]
level-bar: add support for RTL locales
https://bugzilla.gnome.org/show_bug.cgi?id=684288
Stefano Facchini [Tue, 18 Sep 2012 12:05:45 +0000 (14:05 +0200)]
level-bar: add an "inverted" property like GtkProgressBar
https://bugzilla.gnome.org/show_bug.cgi?id=684288
Stefano Facchini [Wed, 19 Sep 2012 11:33:26 +0000 (13:33 +0200)]
Add gdk version macros for 3.8
https://bugzilla.gnome.org/show_bug.cgi?id=684288
Ignacio Casal Quinteiro [Wed, 17 Oct 2012 12:07:31 +0000 (14:07 +0200)]
GtkMenuButton: remove menu property as it is replaced by popup.
See that it was already announced to be removed before 3.6.0
but we forgot.
Cosimo Cecchi [Tue, 16 Oct 2012 18:22:24 +0000 (14:22 -0400)]
cssshadowsvalue: handle gtk_css_value_transition returning NULL
The implementation of transition for GtkCssShadowValue can return NULL
at least when the two values have a different inset; all other parts of
the GTK/CSS machinery (e.g. GtkCssArrayValue) handle this by returning
NULL too. Instead, GtkCssShadowsValue was returning an invalid value,
where "len" was set, but some values in the array were NULL, which would
lead to a segfault when this value is later evaluated by the compute
function.
Fix this by making GtkCssShadowsValue return NULL if a shadow transition
fails, like GtkCssArrayValue does.
https://bugzilla.gnome.org/show_bug.cgi?id=686013
Cosimo Cecchi [Tue, 16 Oct 2012 17:02:55 +0000 (13:02 -0400)]
reftests: fix the linear-gradient reftest
Don't use a repeating linear gradient, since it can't be easily
reftested against a non-repeating one for the reasons described in the
test header.
Instead, add a separate test for repeating gradients (against another
repeating gradient).
This makes the test pass, so it can be added to the Makefile now.
Cosimo Cecchi [Tue, 16 Oct 2012 15:54:33 +0000 (11:54 -0400)]
cssshadow: plug a cairo_surface_t leak
We were never destroying the cairo surface we use for blurring, which
would lead to a huge leak.
https://bugzilla.gnome.org/show_bug.cgi?id=686209
Cosimo Cecchi [Tue, 16 Oct 2012 15:52:59 +0000 (11:52 -0400)]
csskeyframes: unref GtkCssValues when free-ing
We assume a reference to all the GtkCssValues we store, so we need to
release it when free-ing.
Cosimo Cecchi [Tue, 16 Oct 2012 15:51:54 +0000 (11:51 -0400)]
gradient: plug a GtkCssValue refleak
Since _gtk_symbolic_color_resolve_full() returns a reference to a
GtkCssValue.
Cosimo Cecchi [Tue, 16 Oct 2012 15:49:57 +0000 (11:49 -0400)]
csscomputedvalues: plug a refleak
_gtk_css_keyframes_compute() returns a reference to a GtkCssKeyframes,
and _gtk_css_animation_new() takes another reference.
Matthias Clasen [Tue, 16 Oct 2012 10:42:49 +0000 (06:42 -0400)]
bump version
Matthias Clasen [Tue, 16 Oct 2012 02:30:17 +0000 (22:30 -0400)]
3.6.1
Matthias Clasen [Tue, 16 Oct 2012 10:00:40 +0000 (06:00 -0400)]
Fix css parser tests
Parsing a shorthand background property was running into unexpected
errors when trying position values where there were none. To fix this,
introduce a try_parse variant of the position parse function that
silently returns NULL.
Matthias Clasen [Tue, 16 Oct 2012 02:47:30 +0000 (22:47 -0400)]
Fix 'make check'